using System;
using L=Science.Physics.GeneralPhysics;

namespace Serway.Chapter39
{
	/// <summary>
	/// Example11: The Energy of a Speedy Electron
	/// An electron in a television picture tube typically moves 
	/// with a speed u = 0.250c. Find its total energy and 
	/// kinetic energy in electron volts. 
	/// </summary>
	public class Example11
	{
		public Example11()
		{
		}
		private string result;
		public string Result
		{
			get{return result;}
		}
		public void Compute()
		{
			L.Velocity u = new L.Velocity();
			u.X = 0.25*L.Constant.SpeedOfLightInVacuum;
			L.Mass m = new L.Mass();
			m.kg = L.Constant.ElectronMass;
			double E = L.Relativity.TotalEnergy(m,u);
			result+=Convert.ToString(E/L.Constant.ElementaryCharge)+"\r\n";  
		}
	}
}
